package per.dg.keepalive.multiprocess.aidl

import android.content.Intent
import androidx.appcompat.app.AppCompatActivity
import android.os.Bundle
import android.view.View
import per.dg.keepalive.R

class GuardProcessAidlActivity : AppCompatActivity() {
    override fun onCreate(savedInstanceState: Bundle?) {
        super.onCreate(savedInstanceState)
        setContentView(R.layout.activity_guard_process_aidl)
    }

    fun onClick(view: View) {
        when(view.id){
            R.id.bt_start_client_service ->{
                startService(Intent(this, GuardProcessClientService::class.java))
            }
            R.id.bt_close_client_service ->{
                stopService(Intent(this, GuardProcessClientService::class.java))
            }
            R.id.bt_close_server_service ->{
                stopService(Intent(this, GuardProcessServerService::class.java))
            }
        }
    }
}